import Vue from 'vue'
import VueRouter from 'vue-router'

Vue.use(VueRouter)

const routes = [
  // {
  //   path: '/index',
  //   name: 'index',
  //   component: Home,
  //   children:[
  //     {
  //       path: 'lunbo',
  //       name: 'lunbo',
  //       component: Lunbo
  //     }
  //   ]
  // },
  {
    path: '/',
    name: 'Login',
    // route level code-splitting
    // this generates a separate chunk (about.[hash].js) for this route
    // which is lazy-loaded when the route is visited.
    component: () => import( '../views/Login/index.vue')
  },
  {
    path: '/newEquipment',
    name: 'NewEquipment',
    component: () => import( '../views/NewEquipment/index.vue')
  },
  {
    path: '/ballMachineTask',
    name: 'BallMachineTask',
    component: () => import( '../views/BallMachineTask/index.vue')
  },
  {
    path: '/gunMachineTask',
    name: 'GunMachineTask',
    component: () => import( '../views/GunMachineTask/index.vue')
  },
  {
    path: '/tabsPage',
    name: 'TabsPage',
    component: () => import( '../views/TabsPage/index.vue')
  },
]

const router = new VueRouter({
  base: process.env.BASE_URL,
  routes
})

export default router
